﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="ModelMgr.aspx.cs" Inherits="sWarranty.WEB.ModelMgr" %>

<%@ Register Src="../UC/Header.ascx" TagName="Header" TagPrefix="uc1" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
    <title></title>
    <link rel="stylesheet" type="text/css" href="../CSS/table.css" />
    <link rel="stylesheet" type="text/css" href="../CSS/Menu.css" />
    <script src="../JS/jquery-1.8.2.js" type="text/javascript"></script>
    <script src="../JS/Menu.js" type="text/javascript"></script>
    <script src="../JS/jquery.tablesorter.js" type="text/javascript"></script>
    <script type='text/javascript'>
        $(function () {
            $("table").tablesorter({ debug: false });
            //.tablesorterPager({ container: $("#pager") }); 
            SetLogger();
        });
        function openPopUp(popUrl, type) {
            var name = 'popUp';
            var appearence = 'dependent=no,menubar=no,resizable=yes,scrollbars=1,' +
                  'status=yes,toolbar=yes,titlebar=no,' +
                  'width=' + window.screen.availWidth * 80 / 100 + ', height=' + window.screen.availHeight * 80 / 100 + ',resizable:yes,center:yes';
            var openWindow = '';
            if (type == 'open')
                openWindow = window.open(popUrl, name, appearence);
            if (type == 'popup')
                openWindow = window.showModalDialog(popUrl, name, appearence);
            openWindow.focus();
        }

        function nextPage() {
            $('#imgLoadingxyz').show();
            var currentPage = $('#currentPage').val();
            var options = {
                type: 'POST',
                url: 'WebService1.asmx/viewNextShop',
                data: '{currentPage: "' + currentPage + '"}',
                contentType: 'application/json; charset=utf-8',
                dataType: 'json',
                success: function (msg) {
                    $('#xxx').html(msg.d);
                    $('#imgLoadingxyz').hide();
                }
            };
            $.ajax(options);
        }
        function prePage() {
            $('#imgLoadingxyz').show();
            var currentPage = $('#currentPage').val();
            var options = {
                type: 'POST',
                url: 'WebService1.asmx/viewPreShop',
                data: '{currentPage: "' + currentPage + '"}',
                contentType: 'application/json; charset=utf-8',
                dataType: 'json',
                success: function (msg) {
                    $('#xxx').html(msg.d);
                    $('#imgLoadingxyz').hide();
                }
            };
            $.ajax(options);
        }
    </script>
</head>
<body>
    <form id="form1" runat="server">
    <asp:ScriptManager ID="ksdjfl" runat="server">
    </asp:ScriptManager>
    <uc1:Header ID="Header1" runat="server" />
    <div class="Mid">
        <div class="Mid1">
            <div class="Search">
                <table>
                    <tr>
                        <td style="background-color: #F7F7F7">
                            Region :
                        </td>
                        <td>
                            <select style="width: 100%">
                                <option value='NORTH'>NORTH</option>
                                <option value='MIDDLE'>MIDDLE</option>
                                <option value='SOUTH'>SOUTH</option>
                            </select>
                        </td>
                        <td style='width: 10px'>
                        </td>
                        <td style="background-color: #F7F7F7">
                            Customer address :
                        </td>
                        <td>
                            <input type="text" style='width: 100%;'>
                        </td>
                        <td style='width: 10px'>
                        </td>
                        <td>
                        </td>
                    </tr>
                    <tr>
                        <td style="background-color: #F7F7F7">
                            Shop Name :
                        </td>
                        <td>
                            <input type="text" style='width: 100%;'>
                        </td>
                        <td style='width: 10px'>
                        </td>
                        <td style="background-color: #F7F7F7">
                            Shop Address :
                        </td>
                        <td>
                            <input type="text" style='width: 100%'>
                        </td>
                        <td style='width: 10px'>
                        </td>
                        <td>
                            <input type="button" value="Search" style='width: 80px;' />
                        </td>
                    </tr>
                </table>
            </div>
            <div id="DataContent">
                <%-- <div>
                    Nội dung bên trái
                </div>--%>
                <div>
                    <div class="TitleCont">
                        Model Information
                        <img id='imgLoadingxyz' src='../images/oader-grey.gif' style='display: none' />
                        <asp:Button ID="btnRegisterNew" runat="server" CssClass="button Float-right" Font-Names="Tahoma"
                            Width="80px" Text="Register" />
                        <asp:Button ID="btnImport" runat="server" CssClass="button Float-right" Font-Names="Tahoma"
                            Width="80px" Text="Import file" />
                    </div>
                    <div id="xxx" style="height: 100%; overflow: auto; border-left: 1px solid gray;
                        border-right: 1px solid gray;">
                        <!-- DataGrid Start -->
                        <table id="newspaper-b">
                            <thead>
                                <tr>
                                    <th scope="col">
                                        BillTo Code
                                    </th>
                                    <th scope="col">
                                        BillTo Name
                                    </th>
                                    <th scope="col">
                                        Shop Code
                                    </th>
                                    <th scope="col">
                                        Shop Name
                                    </th>
                                    <th scope="col">
                                        Owner Name 
                                    </th>
                                    <th scope="col">
                                        Province
                                    </th>
                                    <th scope="col">
                                        Address
                                    </th>
                                    <th scope="col">
                                        Cell No#1
                                    </th>
                                    <th scope="col">
                                        Cell No#2
                                    </th>
                                    <th scope="col">
                                        Enable
                                    </th>
                                    <th scope="col">
                                        Is Dealer
                                    </th>
                                </tr>
                            </thead>
                            <tbody>
                                <asp:Literal ID="litData" runat="server"></asp:Literal>
                            </tbody>
                        </table>
                        <asp:Literal ID="litPager" runat='server'></asp:Literal>
                    </div>
                </div>
            </div>
            <div class="Clear_both">
            </div>
        </div>
    </div>
    </form>
</body>
</html>
